import Axios from "./index";

export const getUserInfo = (username, password) => {
	return Axios.request({
		url: '/user/doLogin',
		method: 'post',
		data: {username, password}
	})
};

export const login = ({userName, password}) => {
	return Axios.request({
		url: '/login',
		method: 'post',
		data: {userName, password}
	})
};

export const authorization = () => {
	return Axios.request({
		url: '/users/authorization',
		method: 'get'
	});
};
